<!DOCTYPE html>
<html lang="en">
<head>
    <meta http-equiv="content-type" content="text/html; charset=UTF-8">
    <meta charset="utf-8">
    <title></title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1, user-scalable=no">
    <meta name="description" content="">
    <meta name="author" content="">    
</head>
<body>
<script src="../../js/jquery/jquery-2.0.3.min.js"></script>
<!-- BOOTSTRAP -->
<script src="../../bootstrap-dist/js/bootstrap.min.js"></script>
<!-- BLOCK UI -->
<script type="text/javascript" src="../../js/jQuery-BlockUI/jquery.blockUI.min.js"></script>

<!-- AUTOSIZE -->
<script type="text/javascript" src="../../js/autosize/jquery.autosize.min.js"></script>
<!-- spinner -->
<script src="../../js/spinner/spin.js"></script>
<!-- DATA TABLES -->
<script type="text/javascript" src="../../js/datatables/bootstrap-select.js"></script>
<script type="text/javascript" src="../../js/datatables/datatable.js"></script>
<script type="text/javascript" src="../../js/datatables/datatable-bootstrap.js"></script>
<script type="text/javascript" src="../../js/datatables/datatable-tabletools.js"></script>
<script type="text/javascript" src="../../js/datatables/fnAddTr.js"></script>

<!-- INPUT MASK -->
<script type="text/javascript" src="../../js/bootstrap-inputmask/bootstrap-inputmask.min.js"></script>
<!--bootbox-->
<script type="text/javascript" src="../../js/bootbox/bootbox.min.js"></script>
<!-- SELECT2 -->
<script type="text/javascript" src="../../js/select2/select2.min.js"></script>
<!-- UNIFORM -->
<script type="text/javascript" src="../../js/uniform/jquery.uniform.min.js"></script>
<script type="text/javascript" src="../../js/datepicker/datepicker.js"></script>
<!-- COOKIE -->
<script type="text/javascript" src="../../js/jQuery-Cookie/jquery.cookie.min.js"></script>
<script src="../../js/script.js"></script>
<script src="../../js/common.js"></script>

<script>
    var Order = function () {
        var $mainDataTable = null;       
        return {
            init: function () {
            	
            	var orderId=$.getUrlParam("orderId");
            	var totalPrice=$.getUrlParam("totalPrice");
                	$.ajax({
            	          type: "get",
            	          async: false,
            	          url: App.getContextPath() + "agent/alipay/toAlipayApi.do",
            	          data:{state:orderId+"-"+totalPrice+"-AliPay"},
            	          dataType: "json",            	        
            	          success: function(data)
            	          {
            	            if(data.type == "success")
            	            {	            	
            	            	$("body").append(data.extra);

            	            }
            	        }
                	});
               
            }
        }
    }();

    $(function () {
        $("#header").load("../head.html");
        App.init(); //Initialise plugins and elements
        Order.init();
    });
</script>
<!-- /JAVASCRIPTS -->
</body>
</html>